package APong.Entity;

import org.newdawn.slick.Color;
import org.newdawn.slick.GameContainer;
import org.newdawn.slick.Graphics;
import org.newdawn.slick.geom.Rectangle;
import org.newdawn.slick.geom.Shape;
import org.newdawn.slick.state.StateBasedGame;

import APong.World.World;

public class Wall extends Entity {

	protected boolean isHorizontal = true;
	public Wall(World world, float x, float y, int w, int h) {
		super(world, x, y, w, h);
		
	}

	@Override
	protected void renderEntity(GameContainer gc, Graphics g) {
		this.fillCollisionShape(g, Color.green);
	}

	@Override
	protected void updateEntity(GameContainer gc, StateBasedGame sbg) {

	}

	@Override
	public Shape getCollisionShape(float xa, float ya) {
		return new Rectangle((x + (world.getDeltaTime() * xa)), (y + (world.getDeltaTime() * ya)), width, height);
	}

	@Override
	public boolean isSolid(Entity e) {
		return true;
	}

	@Override
	public void collide(Entity e) {
		
		
	}
	public void setIsHorizontal(boolean b){
		this.isHorizontal = b;
	}
	public boolean isHorizontal(boolean b){
		return isHorizontal;
	}

}
